<!DOCTYPE html>
<html>
<#import "spring.ftl" as sp />
<head lang="en">
    <meta charset="UTF-8">
    <title>测试数据绑定2</title>
</head>
<body>
<form method="post" action="/hello/view/addPerson2">
<@sp.message "label.name"/> <input type="text" name="name" value="${(user.name)!}"/>
<#if user??>
    <@sp.bind "user.name" />
    <@sp.showErrors "<br>"/>
</#if>
<@sp.message "label.age"/> <input type="text" name="age" value="${(user.age)!}"/>
<#if user??>
    <@sp.bind "user.age" />
    <@sp.showErrors "<br>"/>
</#if>

<@sp.message "label.email"/> <input type="text" name="email" value="${(user.email)!}"/>
<#if user??>
    <@sp.bind "user.email" />
    <@sp.showErrors "<br>"/>
</#if> <input type="submit" value="提交2">
</form>

</body>
</html>